#!/bin/bash

DATAFILE=/data/lyp/datasets/covid.txt
BUILD_DIR=/home/lyp/dnskv/build
STORE_DIR=/data/lyp/ycsb100-50m

mkdir ${STORE_DIR}

# ./YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F /data/lyp/datasets/covid.txt -P ./YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloada.spec

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloada.spec --query_only
# mv dataset.dat ${STORE_DIR}/dataset.dat
mv query.dat ${STORE_DIR}/query_a.dat

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloadb.spec --query_only
mv query.dat ${STORE_DIR}/query_b.dat

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloadc.spec --query_only
mv query.dat ${STORE_DIR}/query_c.dat

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloadd.spec --query_only
mv query.dat ${STORE_DIR}/query_d.dat

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloade.spec --query_only
mv query.dat ${STORE_DIR}/query_e.dat

${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen-build/ycsbc -F ${DATAFILE} \
                                            -P ${BUILD_DIR}/YCSB-Gen-prefix/src/YCSB-Gen/workloads/workloadf.spec --query_only
mv query.dat ${STORE_DIR}/query_f.dat